#!/usr/bin/perl -w
use strict;
use Data::Dumper;
use JSON;

my $hostname = "test.line0.com";
my $img_id = "a18ef010d675";

my $hash_ref = {
	Hostname => $hostname,
    Cmd => ["/usr/sbin/sshd","-D"],
	Image => "$img_id",
	Names => "",
	ExposedPorts => {
		    "8080/tcp" => {},
		    "22/tcp" => {},
	},
	Dns => ["203.95.1.2","203.95.7.1"],
	Volumes => {
		"/opt/software" => {}, 
        "/etc/localtime" => {"ro"},
	},

    HostConfig => { Binds => ["/opt/software:/opt/software","/etc/localtime:/etc/localtime"],},
};

my $json = new JSON;
my $respone = $json->encode($hash_ref);
print Dumper($respone);
#my $encode_json = $json->decode($respone);
#print Dumper($encode_json);
